package com.zyd.mappers;

import com.zyd.io.model.VehicleEntity;
import com.zyd.io.model.VehicleEntityExample;
import com.zyd.io.model.VehicleEntityKey;
import java.util.List;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.DeleteProvider;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.InsertProvider;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Result;
import org.apache.ibatis.annotations.Results;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.SelectProvider;
import org.apache.ibatis.annotations.Update;
import org.apache.ibatis.annotations.UpdateProvider;
import org.apache.ibatis.type.JdbcType;

public interface VehicleEntityMapper {
    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table zydzn_vehicle
     *
     * @mbg.generated Fri Feb 15 17:34:15 CST 2019
     */
    @SelectProvider(type=VehicleEntitySqlProvider.class, method="countByExample")
    long countByExample(VehicleEntityExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table zydzn_vehicle
     *
     * @mbg.generated Fri Feb 15 17:34:15 CST 2019
     */
    @DeleteProvider(type=VehicleEntitySqlProvider.class, method="deleteByExample")
    int deleteByExample(VehicleEntityExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table zydzn_vehicle
     *
     * @mbg.generated Fri Feb 15 17:34:15 CST 2019
     */
    @Delete({
        "delete from zydzn_vehicle",
        "where id = #{id,jdbcType=VARCHAR}"
    })
    int deleteByPrimaryKey(VehicleEntityKey key);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table zydzn_vehicle
     *
     * @mbg.generated Fri Feb 15 17:34:15 CST 2019
     */
    @Insert({
        "insert into zydzn_vehicle (id, carname, ",
        "carid, sex, mobile, ",
        "vocation, vehiclebrand, ",
        "mobileback, ispromise, ",
        "caraddress, vinno, ",
        "bugprice, theftnum, ",
        "degree, carcolour, ",
        "tagcode, keeptime, ",
        "bugtime, startmachine, ",
        "specialclass, lighttypes, ",
        "regtime, area, salesite, ",
        "img1, img2, img3, ",
        "createtime, ts, ",
        "createid, dr, reger, ",
        "userid, cartype, ",
        "isbindapp, newareaid, ",
        "islock)",
        "values (#{id,jdbcType=VARCHAR}, #{carname,jdbcType=VARCHAR}, ",
        "#{carid,jdbcType=VARCHAR}, #{sex,jdbcType=INTEGER}, #{mobile,jdbcType=VARCHAR}, ",
        "#{vocation,jdbcType=VARCHAR}, #{vehiclebrand,jdbcType=VARCHAR}, ",
        "#{mobileback,jdbcType=VARCHAR}, #{ispromise,jdbcType=INTEGER}, ",
        "#{caraddress,jdbcType=VARCHAR}, #{vinno,jdbcType=VARCHAR}, ",
        "#{bugprice,jdbcType=DECIMAL}, #{theftnum,jdbcType=VARCHAR}, ",
        "#{degree,jdbcType=INTEGER}, #{carcolour,jdbcType=VARCHAR}, ",
        "#{tagcode,jdbcType=VARCHAR}, #{keeptime,jdbcType=VARCHAR}, ",
        "#{bugtime,jdbcType=VARCHAR}, #{startmachine,jdbcType=VARCHAR}, ",
        "#{specialclass,jdbcType=VARCHAR}, #{lighttypes,jdbcType=VARCHAR}, ",
        "#{regtime,jdbcType=VARCHAR}, #{area,jdbcType=VARCHAR}, #{salesite,jdbcType=VARCHAR}, ",
        "#{img1,jdbcType=VARCHAR}, #{img2,jdbcType=VARCHAR}, #{img3,jdbcType=VARCHAR}, ",
        "#{createtime,jdbcType=VARCHAR}, #{ts,jdbcType=VARCHAR}, ",
        "#{createid,jdbcType=VARCHAR}, #{dr,jdbcType=INTEGER}, #{reger,jdbcType=VARCHAR}, ",
        "#{userid,jdbcType=VARCHAR}, #{cartype,jdbcType=VARCHAR}, ",
        "#{isbindapp,jdbcType=INTEGER}, #{newareaid,jdbcType=VARCHAR}, ",
        "#{islock,jdbcType=INTEGER})"
    })
    int insert(VehicleEntity record);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table zydzn_vehicle
     *
     * @mbg.generated Fri Feb 15 17:34:15 CST 2019
     */
    @InsertProvider(type=VehicleEntitySqlProvider.class, method="insertSelective")
    int insertSelective(VehicleEntity record);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table zydzn_vehicle
     *
     * @mbg.generated Fri Feb 15 17:34:15 CST 2019
     */
    @SelectProvider(type=VehicleEntitySqlProvider.class, method="selectByExample")
    @Results({
        @Result(column="id", property="id", jdbcType=JdbcType.VARCHAR, id=true),
        @Result(column="carname", property="carname", jdbcType=JdbcType.VARCHAR),
        @Result(column="carid", property="carid", jdbcType=JdbcType.VARCHAR),
        @Result(column="sex", property="sex", jdbcType=JdbcType.INTEGER),
        @Result(column="mobile", property="mobile", jdbcType=JdbcType.VARCHAR),
        @Result(column="vocation", property="vocation", jdbcType=JdbcType.VARCHAR),
        @Result(column="vehiclebrand", property="vehiclebrand", jdbcType=JdbcType.VARCHAR),
        @Result(column="mobileback", property="mobileback", jdbcType=JdbcType.VARCHAR),
        @Result(column="ispromise", property="ispromise", jdbcType=JdbcType.INTEGER),
        @Result(column="caraddress", property="caraddress", jdbcType=JdbcType.VARCHAR),
        @Result(column="vinno", property="vinno", jdbcType=JdbcType.VARCHAR),
        @Result(column="bugprice", property="bugprice", jdbcType=JdbcType.DECIMAL),
        @Result(column="theftnum", property="theftnum", jdbcType=JdbcType.VARCHAR),
        @Result(column="degree", property="degree", jdbcType=JdbcType.INTEGER),
        @Result(column="carcolour", property="carcolour", jdbcType=JdbcType.VARCHAR),
        @Result(column="tagcode", property="tagcode", jdbcType=JdbcType.VARCHAR),
        @Result(column="keeptime", property="keeptime", jdbcType=JdbcType.VARCHAR),
        @Result(column="bugtime", property="bugtime", jdbcType=JdbcType.VARCHAR),
        @Result(column="startmachine", property="startmachine", jdbcType=JdbcType.VARCHAR),
        @Result(column="specialclass", property="specialclass", jdbcType=JdbcType.VARCHAR),
        @Result(column="lighttypes", property="lighttypes", jdbcType=JdbcType.VARCHAR),
        @Result(column="regtime", property="regtime", jdbcType=JdbcType.VARCHAR),
        @Result(column="area", property="area", jdbcType=JdbcType.VARCHAR),
        @Result(column="salesite", property="salesite", jdbcType=JdbcType.VARCHAR),
        @Result(column="img1", property="img1", jdbcType=JdbcType.VARCHAR),
        @Result(column="img2", property="img2", jdbcType=JdbcType.VARCHAR),
        @Result(column="img3", property="img3", jdbcType=JdbcType.VARCHAR),
        @Result(column="createtime", property="createtime", jdbcType=JdbcType.VARCHAR),
        @Result(column="ts", property="ts", jdbcType=JdbcType.VARCHAR),
        @Result(column="createid", property="createid", jdbcType=JdbcType.VARCHAR),
        @Result(column="dr", property="dr", jdbcType=JdbcType.INTEGER),
        @Result(column="reger", property="reger", jdbcType=JdbcType.VARCHAR),
        @Result(column="userid", property="userid", jdbcType=JdbcType.VARCHAR),
        @Result(column="cartype", property="cartype", jdbcType=JdbcType.VARCHAR),
        @Result(column="isbindapp", property="isbindapp", jdbcType=JdbcType.INTEGER),
        @Result(column="newareaid", property="newareaid", jdbcType=JdbcType.VARCHAR),
        @Result(column="islock", property="islock", jdbcType=JdbcType.INTEGER)
    })
    List<VehicleEntity> selectByExample(VehicleEntityExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table zydzn_vehicle
     *
     * @mbg.generated Fri Feb 15 17:34:15 CST 2019
     */
    @Select({
        "select",
        "id, carname, carid, sex, mobile, vocation, vehiclebrand, mobileback, ispromise, ",
        "caraddress, vinno, bugprice, theftnum, degree, carcolour, tagcode, keeptime, ",
        "bugtime, startmachine, specialclass, lighttypes, regtime, area, salesite, img1, ",
        "img2, img3, createtime, ts, createid, dr, reger, userid, cartype, isbindapp, ",
        "newareaid, islock",
        "from zydzn_vehicle",
        "where id = #{id,jdbcType=VARCHAR}"
    })
    @Results({
        @Result(column="id", property="id", jdbcType=JdbcType.VARCHAR, id=true),
        @Result(column="carname", property="carname", jdbcType=JdbcType.VARCHAR),
        @Result(column="carid", property="carid", jdbcType=JdbcType.VARCHAR),
        @Result(column="sex", property="sex", jdbcType=JdbcType.INTEGER),
        @Result(column="mobile", property="mobile", jdbcType=JdbcType.VARCHAR),
        @Result(column="vocation", property="vocation", jdbcType=JdbcType.VARCHAR),
        @Result(column="vehiclebrand", property="vehiclebrand", jdbcType=JdbcType.VARCHAR),
        @Result(column="mobileback", property="mobileback", jdbcType=JdbcType.VARCHAR),
        @Result(column="ispromise", property="ispromise", jdbcType=JdbcType.INTEGER),
        @Result(column="caraddress", property="caraddress", jdbcType=JdbcType.VARCHAR),
        @Result(column="vinno", property="vinno", jdbcType=JdbcType.VARCHAR),
        @Result(column="bugprice", property="bugprice", jdbcType=JdbcType.DECIMAL),
        @Result(column="theftnum", property="theftnum", jdbcType=JdbcType.VARCHAR),
        @Result(column="degree", property="degree", jdbcType=JdbcType.INTEGER),
        @Result(column="carcolour", property="carcolour", jdbcType=JdbcType.VARCHAR),
        @Result(column="tagcode", property="tagcode", jdbcType=JdbcType.VARCHAR),
        @Result(column="keeptime", property="keeptime", jdbcType=JdbcType.VARCHAR),
        @Result(column="bugtime", property="bugtime", jdbcType=JdbcType.VARCHAR),
        @Result(column="startmachine", property="startmachine", jdbcType=JdbcType.VARCHAR),
        @Result(column="specialclass", property="specialclass", jdbcType=JdbcType.VARCHAR),
        @Result(column="lighttypes", property="lighttypes", jdbcType=JdbcType.VARCHAR),
        @Result(column="regtime", property="regtime", jdbcType=JdbcType.VARCHAR),
        @Result(column="area", property="area", jdbcType=JdbcType.VARCHAR),
        @Result(column="salesite", property="salesite", jdbcType=JdbcType.VARCHAR),
        @Result(column="img1", property="img1", jdbcType=JdbcType.VARCHAR),
        @Result(column="img2", property="img2", jdbcType=JdbcType.VARCHAR),
        @Result(column="img3", property="img3", jdbcType=JdbcType.VARCHAR),
        @Result(column="createtime", property="createtime", jdbcType=JdbcType.VARCHAR),
        @Result(column="ts", property="ts", jdbcType=JdbcType.VARCHAR),
        @Result(column="createid", property="createid", jdbcType=JdbcType.VARCHAR),
        @Result(column="dr", property="dr", jdbcType=JdbcType.INTEGER),
        @Result(column="reger", property="reger", jdbcType=JdbcType.VARCHAR),
        @Result(column="userid", property="userid", jdbcType=JdbcType.VARCHAR),
        @Result(column="cartype", property="cartype", jdbcType=JdbcType.VARCHAR),
        @Result(column="isbindapp", property="isbindapp", jdbcType=JdbcType.INTEGER),
        @Result(column="newareaid", property="newareaid", jdbcType=JdbcType.VARCHAR),
        @Result(column="islock", property="islock", jdbcType=JdbcType.INTEGER)
    })
    VehicleEntity selectByPrimaryKey(VehicleEntityKey key);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table zydzn_vehicle
     *
     * @mbg.generated Fri Feb 15 17:34:15 CST 2019
     */
    @UpdateProvider(type=VehicleEntitySqlProvider.class, method="updateByExampleSelective")
    int updateByExampleSelective(@Param("record") VehicleEntity record, @Param("example") VehicleEntityExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table zydzn_vehicle
     *
     * @mbg.generated Fri Feb 15 17:34:15 CST 2019
     */
    @UpdateProvider(type=VehicleEntitySqlProvider.class, method="updateByExample")
    int updateByExample(@Param("record") VehicleEntity record, @Param("example") VehicleEntityExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table zydzn_vehicle
     *
     * @mbg.generated Fri Feb 15 17:34:15 CST 2019
     */
    @UpdateProvider(type=VehicleEntitySqlProvider.class, method="updateByPrimaryKeySelective")
    int updateByPrimaryKeySelective(VehicleEntity record);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table zydzn_vehicle
     *
     * @mbg.generated Fri Feb 15 17:34:15 CST 2019
     */
    @Update({
        "update zydzn_vehicle",
        "set carname = #{carname,jdbcType=VARCHAR},",
          "carid = #{carid,jdbcType=VARCHAR},",
          "sex = #{sex,jdbcType=INTEGER},",
          "mobile = #{mobile,jdbcType=VARCHAR},",
          "vocation = #{vocation,jdbcType=VARCHAR},",
          "vehiclebrand = #{vehiclebrand,jdbcType=VARCHAR},",
          "mobileback = #{mobileback,jdbcType=VARCHAR},",
          "ispromise = #{ispromise,jdbcType=INTEGER},",
          "caraddress = #{caraddress,jdbcType=VARCHAR},",
          "vinno = #{vinno,jdbcType=VARCHAR},",
          "bugprice = #{bugprice,jdbcType=DECIMAL},",
          "theftnum = #{theftnum,jdbcType=VARCHAR},",
          "degree = #{degree,jdbcType=INTEGER},",
          "carcolour = #{carcolour,jdbcType=VARCHAR},",
          "tagcode = #{tagcode,jdbcType=VARCHAR},",
          "keeptime = #{keeptime,jdbcType=VARCHAR},",
          "bugtime = #{bugtime,jdbcType=VARCHAR},",
          "startmachine = #{startmachine,jdbcType=VARCHAR},",
          "specialclass = #{specialclass,jdbcType=VARCHAR},",
          "lighttypes = #{lighttypes,jdbcType=VARCHAR},",
          "regtime = #{regtime,jdbcType=VARCHAR},",
          "area = #{area,jdbcType=VARCHAR},",
          "salesite = #{salesite,jdbcType=VARCHAR},",
          "img1 = #{img1,jdbcType=VARCHAR},",
          "img2 = #{img2,jdbcType=VARCHAR},",
          "img3 = #{img3,jdbcType=VARCHAR},",
          "createtime = #{createtime,jdbcType=VARCHAR},",
          "ts = #{ts,jdbcType=VARCHAR},",
          "createid = #{createid,jdbcType=VARCHAR},",
          "dr = #{dr,jdbcType=INTEGER},",
          "reger = #{reger,jdbcType=VARCHAR},",
          "userid = #{userid,jdbcType=VARCHAR},",
          "cartype = #{cartype,jdbcType=VARCHAR},",
          "isbindapp = #{isbindapp,jdbcType=INTEGER},",
          "newareaid = #{newareaid,jdbcType=VARCHAR},",
          "islock = #{islock,jdbcType=INTEGER}",
        "where id = #{id,jdbcType=VARCHAR}"
    })
    int updateByPrimaryKey(VehicleEntity record);
}